from manimlib import *
from numpy import flip, insert

LV,QL,QH,JH='#75cfb8','#bbdfc8','#f0e5d8','#ffc478'

class p1(Scene):
    def construct(self):
        # self.camera.frame.save_state()
        # self.add(NumberPlane())
        # self.camera.frame.rotate(13*DEGREES,about_point=[0.0, 0.0, 1.0])
        a,b,c,d=[-6,3,0],[4,3,0],[6,-3,0],[-4,-3,0]
        abcd=Polygon(a,b,c,d)
        m,n,p=[-3,3,0],[3,-3,0],[5+1/3,-1,0]
        ap,dp,dm,mn,bn=Line(a,p),Line(d,p),Line(d,m),Line(m,n),Line(b,n)
        self.add(abcd,ap,dp,dm,mn,bn
        )
        self.add(
            Tex('A').next_to(a,UP),
            Tex('B').next_to(b,UP),
            Tex('C').next_to(c,DOWN),
            Tex('D').next_to(d,DOWN),
            Tex('?').move_to([-3.8,2.6,0]),
            Tex('79').move_to([-2,-1,0]),
            Tex('72').move_to([1.8,1.8,0]),
            Tex('10').move_to([4,-1,0]),
            Tex('8').move_to([2.6,-2,0]),
            Tex('M').next_to(m,UP),
            Tex('N').next_to(n,DOWN),
            Tex('P').next_to(p)
        )
        self.wait()

